var x = "fred"
var y = 14 + makeIt(x)
println(y)

	var acc = 0;
	for (var idx = 0; idx < 10; idx++)
		acc += idx;

	println(acc)

	var fn = function(x) { return x + 4 }

	println(fn(5))

	var obj = {
	a: 10,
	b: 20
	};

	println(obj.b);

	println(Math.cos(0.5))

	var arr = [1, 4, 7];

	println(arr.length)

	println(arr[1])

	arr[1] = "froggy"

	println(arr[1])

	obj.spam = 56.4

	println(obj["spam"])


var closure = functor(12);

println(closure);

println(closure(5));

function makeIt(z) {
	return z + 4
}

function functor(z) {
	return function(x) { return x + z }
}
